//package com.wica.view;
//
//import android.app.Activity;
//import android.content.Intent;
//import android.os.Bundle;
//import android.util.Log;
//import android.view.KeyEvent;
//import android.view.Menu;
//import android.view.MenuItem;
//import android.view.View;
//import android.view.Window;
//import android.view.View.OnClickListener;
//import android.view.View.OnKeyListener;
//import android.widget.Button;
//import android.widget.EditText;
//import android.widget.TextView;
//import android.widget.Toast;
//
//public class InvokeSurvey extends Activity implements OnKeyListener{
//	
//	// *************** Constants ************** //  
//	// Log constants
//    protected static final String LOG_TAG = "Survey.DialogActivity";
//    
//    // *************** Attributes ************************* //
//	private Button yes,exit;
//	private EditText searchStringEditText;
//	private OnClickListener yesListener;
//	private static final int SETTINGS = Menu.FIRST+1;
//	private static final int SET_MOOD = Menu.FIRST+2;
//	private static final int SET_TEXTLOCATION = Menu.FIRST+3;
//	// Request code for ActivityForResult
//	private static final int REQUESTCODE_MOOD = 1;
//	private static final int REQUESTCODE_TEXTLOCATION = 2;
//	private static final int REQUESTCODE_SETTINGS = 3;
//
//	// *************** Methods **************************** //
//    @Override
//	protected void onCreate(Bundle savedInstanceState) {
//        // Be sure to call the super class.
//        super.onCreate(savedInstanceState);  
//        
//        // Inflate our UI from its XML layout description.
//        setContentView(R.layout.survey);
//
//        // Get display items for later interaction
//        yes = (Button) findViewById(R.id.btn_yes);
//        exit = (Button) findViewById(R.id.btn_exit);
//        searchStringEditText = (EditText) findViewById(R.id.txt_query_prefill);
//        
//        // Attach actions to buttons
//    	yesListener = new OnClickListener() {
//            public void onClick(View v) {
//            	// return data from EditText
//                Intent intent = new Intent(InvokeSurvey.this, Rating.class);
//                intent.putExtra("searchString", searchStringEditText.getText().toString());
//            	setResult(RESULT_OK,intent);
//            	Log.v(LOG_TAG,LOG_TAG+"devolvemos el control");
//            	finish();
//            }
//        };
//        yes.setOnClickListener(yesListener);         
//        exit.setOnClickListener(
//        		new OnClickListener() {
//                    public void onClick(View v) {
//                    	finish();
//                    }
//                });
//
//    }
//    
//	@Override
//	public boolean onKey(View v, int keyCode, KeyEvent event) {
//		if (keyCode == KeyEvent.KEYCODE_BACK || keyCode==KeyEvent.KEYCODE_HOME){		
//    		Toast.makeText(this, "Please select wether you want to fulfill the survey or not", Toast.LENGTH_LONG).show();			
//			return false;
//  	  	}else {
//  	  		return super.onKeyDown(keyCode, event);
//  	  	}
//	}
//    
//}
